const Setting = require("./models/Setting");

exports.getSetting = async () => {
    const ins = await Setting.findOne();
    return ins.toJSON();
}

exports.setSetting = async (info) => {
    await Setting.update(info, {
        where: {
            id: 1
        }
    });
    const ins = await Setting.findOne();
    return ins.toJSON();
}
